package view.action;

import java.util.List;

import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;

import model.Task;
import controller.factory.AbstractFactory;

public class ActionPreparedSearch implements Action {

	@Override
	public String execute(HttpServletRequest request,
			HttpServletResponse response) throws Exception {
		List<Task> tasks = AbstractFactory.getNewInstance().getDAOTask().getAll();
		request.getSession().setAttribute("tasks", tasks);
		return "/secured/search.jsp";
	}

}
